home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Tools / Languages / Icon 8.1 / msm-2 / tests.sit / tests / stand / checkfpc.out < prev    next >
Encoding:
Text File  |  1992-12-08  |  3.9 KB  |  284 lines  |  [TEXT/????]

  1. This test of floating-point arithmetic is likely to show
  2. differences from platform to platform because of differences
  3. in floating-point precision and details of the routines that
  4. convert floating-point numbers to strings.  If the values
  5. produced in local tests are approximately the same in magnitude
  6. as shown in the standard results, there's nothing to worry about.
  7. In addition, some platforms may show 0.0 as "-0.0".  You can
  8. ignore this if you wish.
  9. 0.21132
  10. 0.41242
  11. 0.31579
  12. 0.51044
  13. 0.42173
  14. 0.30569
  15. 0.07960
  16. 0.73752
  17. 0.05072
  18. 0.71694
  19. every 1 to 10 do write(?0) ----> none
  20. 2.0
  21. 2.0
  22. 2.0
  23. 2.0
  24. 2.0
  25. 2.0
  26. 2.0
  27. 2.0
  28. 2.0
  29. 2.0
  30. 2.0
  31. 2.0
  32. 2.0
  33. 2.0
  34. 2.0
  35. 2.0
  36. 2.0
  37. 2.0
  38. 2.0
  39. 2.0
  40. 2.0
  41. 2.0
  42. 2.0
  43. 2.0
  44. 2.0
  45. 2.0
  46. 2.0
  47. 2.0
  48. 2.0
  49. 2.0
  50. 2.0
  51. 2.0
  52. 2.0
  53. 2.0
  54. 2.0
  55. 2.0
  56. 2.0
  57. 2.0
  58. 2.0
  59. 2.0
  60. 2.0
  61. 2.0
  62. 2.0
  63. 2.0
  64. 2.0
  65. 2.0
  66. 2.0
  67. 2.0
  68. 2.0
  69. 2.0
  70. every i := 1 to 50 do write(real(repl("0",i) || "2.")) ----> none
  71. 2
  72. 2
  73. 2
  74. 2
  75. 2
  76. 2
  77. 2
  78. 2
  79. 2
  80. 2
  81. 2
  82. 2
  83. 2
  84. 2
  85. 2
  86. 2
  87. 2
  88. 2
  89. 2
  90. 2
  91. 2
  92. 2
  93. 2
  94. 2
  95. 2
  96. 2
  97. 2
  98. 2
  99. 2
  100. 2
  101. every i := 1 to 30 do write(integer(repl("0",i) || "2")) ----> none
  102. 2.0 ~=== +2.0 ----> none
  103. abs(3.0) ----> 3.0
  104. Image(2e13) ----> "2.e+13"
  105. Image(0.0006) ----> "0.0006"
  106. Image(2.0) ----> "2.0"
  107. integer(2.0) ----> 2
  108. integer(2.7) ----> 2
  109. integer(".") ----> none
  110. integer(".3") ----> 0
  111. integer("0.3") ----> 0
  112. integer(" . 3") ----> none
  113. integer("e2") ----> none
  114. integer("3e500") ----> none
  115. numeric(2.0) ----> 2.0
  116. numeric(2.7) ----> 2.7
  117. numeric(".") ----> none
  118. numeric(".3") ----> 0.3
  119. numeric("0.3") ----> 0.3
  120. numeric(" . 3") ----> none
  121. numeric("e2") ----> none
  122. numeric("3e500") ----> none
  123. real(2) ----> 2.0
  124. real(2.0) ----> 2.0
  125. real(2.7) ----> 2.7
  126. real("2") ----> 2.0
  127. real(" 2") ----> 2.0
  128. real("2 ") ----> 2.0
  129. real("+2") ----> 2.0
  130. real("-2") ----> -2.0
  131. real("- 2") ----> none
  132. real(" -    2 ") ----> none
  133. real("") ----> none
  134. real("--2") ----> none
  135. real(" ") ----> none
  136. real("-") ----> none
  137. real("+") ----> none
  138. real(".") ----> none
  139. real(".3") ----> 0.3
  140. real("0.3") ----> 0.3
  141. real(" . 3") ----> none
  142. real("e2") ----> none
  143. real("3e500") ----> none
  144. real("7r4") ----> 4.0
  145. real("4r7") ----> none
  146. real("4r 7") ----> none
  147. real("7r 4") ----> none
  148. real("16rff") ----> 255.0
  149. real("36rcat") ----> 15941.0
  150. real("36Rcat") ----> 15941.0
  151. real("36rCAT") ----> 15941.0
  152. real("1r1") ----> none
  153. real("2r0") ----> 0.0
  154. real("22222222222222222222222222222") ----> none
  155. numeric(2.0) ----> 2.0
  156. numeric(2.7) ----> 2.7
  157. numeric(0.3) ----> 0.3
  158. numeric(e2) ----> none
  159. 36. ^ 9 ----> 1.015599e+14
  160. 36 ^ 9. ----> 1.015599e+14
  161. 36. ^ 9. ----> 1.015599e+14
  162. -36. ^ 9 ----> -.101559e+15
  163. -36. ^ -9 ----> -9.84640e-15
  164. 2.0
  165. 22.0
  166. 222.0
  167. 2222.0
  168. 22222.0
  169. 222222.0
  170. 2.222222e+6
  171. 2.222222e+7
  172. 2.222222e+8
  173. 2.222222e+9
  174. 2.222222e+10
  175. 2.222222e+11
  176. 2.222222e+12
  177. 2.222222e+13
  178. 2.222222e+14
  179. 2.222222e+15
  180. 2.222222e+16
  181. 2.222222e+17
  182. 2.222222e+18
  183. 2.222222e+19
  184. 2.222222e+20
  185. 2.222222e+21
  186. 2.222222e+22
  187. 2.222222e+23
  188. 2.222222e+24
  189. 2.222222e+25
  190. 2.222222e+26
  191. 2.222222e+27
  192. 2.222222e+28
  193. 2.222222e+29
  194. 2.222222e+30
  195. 2.222222e+31
  196. 2.222222e+32
  197. 2.222222e+33
  198. 2.222222e+34
  199. 2.222222e+35
  200. 2.222222e+36
  201. failed
  202. 2.2
  203. 22.2
  204. 222.2
  205. 2222.2
  206. 22222.2
  207. 222222.2
  208. 2.222222e+6
  209. 2.222222e+7
  210. 2.222222e+8
  211. 2.222222e+9
  212. 2.222222e+10
  213. 2.222222e+11
  214. 2.222222e+12
  215. 2.222222e+13
  216. 2.222222e+14
  217. 2.222222e+15
  218. 2.222222e+16
  219. 2.222222e+17
  220. 2.222222e+18
  221. 2.222222e+19
  222. 2.222222e+20
  223. 2.222222e+21
  224. 2.222222e+22
  225. 2.222222e+23
  226. 2.222222e+24
  227. 2.222222e+25
  228. 2.222222e+26
  229. 2.222222e+27
  230. 2.222222e+28
  231. 2.222222e+29
  232. 2.222222e+30
  233. 2.222222e+31
  234. 2.222222e+32
  235. 2.222222e+33
  236. 2.222222e+34
  237. 2.222222e+35
  238. 2.222222e+36
  239. failed
  240. 3.2
  241. 23.2
  242. 223.2
  243. 2223.2
  244. 22223.2
  245. 222223.2
  246. 2.222223e+6
  247. 2.222222e+7
  248. 2.222222e+8
  249. 2.222222e+9
  250. 2.222222e+10
  251. 2.222222e+11
  252. 2.222222e+12
  253. 2.222222e+13
  254. 2.222222e+14
  255. 2.222222e+15
  256. 2.222222e+16
  257. 2.222222e+17
  258. 2.222222e+18
  259. 2.222222e+19
  260. 2.222222e+20
  261. 2.222222e+21
  262. 2.222222e+22
  263. 2.222222e+23
  264. 2.222222e+24
  265. 2.222222e+25
  266. 2.222222e+26
  267. 2.222222e+27
  268. 2.222222e+28
  269. 2.222222e+29
  270. 2.222222e+30
  271. 2.222222e+31
  272. 2.222222e+32
  273. 2.222222e+33
  274. 2.222222e+34
  275. 2.222222e+35
  276. 2.222222e+36
  277. failed
  278. 2.0 === +2.0 ----> 2.0
  279. ?30.0 ----> 5
  280. copy(1.0) ----> 1.0
  281. trim(3.14159,58) ----> "3.14159"
  282. Image(2e13) ----> "2.e+13"
  283. Image(0.0006) ----> "0.0006"
  284.